﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using iOak.Data.Resumes;
using iOak.Domain.Resumes;

namespace iOak.Business.Resumes
{
    public partial  class AttachmentService
    {
        private AttachementRepository _attachmentRepository;
        public AttachmentService()
        {
            _attachmentRepository = new AttachementRepository("master");
        }

        public void Create(Attachement item)
        {
            _attachmentRepository.Create(item);
        }

        public Attachement Retrieve(Guid attachmentId)
        {
            return _attachmentRepository.Retrieve(attachmentId);
        }

        public void Update(Attachement item)
        {
            _attachmentRepository.Update(item);
        }

        public void Delete(Guid attachmentId)
        {
            _attachmentRepository.Delete(attachmentId);
        }

        public List<Attachement> SearchByResumeId(Guid resumeId)
        {
            return _attachmentRepository.SearchByResumeId(resumeId);
        }

        public List<Attachement> LoadAll()
        {
            return _attachmentRepository.LoadAll();
        }
    }
}
